<script setup>
import {useRouter} from "vue-router";
import {UseUserStore, UseSocketStore} from '@/stores/index.js'

let userStore = UseUserStore()
let socketStore = UseSocketStore()
let router = useRouter()

function backClick() {
  router.push('/home')
  // 重置
  socketStore.disconnectSocket()
  userStore.userInfo = {}
  localStorage.clear()
}
</script>

<template>
  <div class="w-12  h-full flex justify-center items-center ">
    <div
        class="shadow-md rounded-full w-10 h-10 border border-gray-400 flex justify-center items-center m-auto hover:bg-blue-500 *:hover:text-white   transition-all  ease-in-out delay-80"
        @click="backClick">
      <span aria-hidden="true" class="icon-[ic--baseline-arrow-back-ios] ml-1.5" role="img"></span>
    </div>
  </div>
</template>

<style scoped>

</style>